package com.yanqu.road.reids.subpub;

public enum  eRedisChannelType {

    LunTanSignIn(1, "lunTanSignIn", "signIn"){
        @Override
        public String getMessageKey(String message) {
            return super.getMessageKey(message);
        }
    },

    SystemConfig(2, "systemConfig", "systemConfig"){
        @Override
        public String getMessageKey(String message) {
            return super.getMessageKey(message);
        }
    },

    ZfbIndex(3, "zfbIndex", "zfbIndex"){
        @Override
        public String getMessageKey(String message) {
            return super.getMessageKey(message);
        }
    },

    CenterManagerReload(10, "CenterManagerReload", "CenterManagerReload"),
    ;

    int type;

    String channel;

    String keyPrefix;

    public String getMessageKey(String message){
        return getKeyPrefix() + ";" + message;
    }

    eRedisChannelType(int type, String channel, String keyPrefix) {
        this.type = type;
        this.channel = channel;
        this.keyPrefix = keyPrefix;
    }

    public int getType() {
        return type;
    }

    public void setType(int type) {
        this.type = type;
    }

    public String getChannel() {
        return channel;
    }

    public void setChannel(String channel) {
        this.channel = channel;
    }

    public String getKeyPrefix() {
        return keyPrefix;
    }

    public void setKeyPrefix(String keyPrefix) {
        this.keyPrefix = keyPrefix;
    }
}
